class AddTestDataForLocations < ActiveRecord::Migration
  def self.up
    country = Country.create(:country_name => "South Africa")
    city = City.create(:city_name => "Port Elizabeth", :country => country)
    Suburb.create(:suburb_name => "Lorraine", :city => city)
    Suburb.create(:suburb_name => "Walmer", :city => city)
    Suburb.create(:suburb_name => "Newton Park", :city => city)
  end

  def self.down
    Suburb.destroy_all
    City.destroy_all
    Country.destroy_all
  end
end
